Add the ability for the developer to specify other XML elements to parse.#43
Open
macoss wants to merge 3 commits intomwaterfall:masterfrom
macoss:master
Open
Add the ability for the developer to specify other XML elements to parse.#43macoss wants to merge 3 commits intomwaterfall:masterfrom macoss:master
macoss wants to merge 3 commits intomwaterfall:masterfrom
macoss:master
Conversation
I have added a NSArray that is used to pass in a list of NSStrings that is to contain the xml element names of the custom elements that you would like MWFeedParser to look for and parse if it is found. If the elements are found they will be added to the customProperities NSDictionary that I have added to the MWFeedItem class.
…error Added documentation to the README and fixed a spelling error in the dictionary name.
|
I really need this for parsing a format called GeoRSS based on RSS 1. To me it seames like @macoss has implemented a simple XPath based XML extension parser, but I can find no examples of usage, and it is not commited back to the mwaterfall / MWFeedParser branch. Is this piece of code able to parse georss:pointlogitude latitude/georss:point within each item? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a NSArray object to the MWFeedParser class (customKeys) that can be used to pass string identifiers to the parser. The parser then compares these keys during the parse and if an element with that name is found the key and the sting value will be added to a dictionary on the MWFeedItem class called customProperties. This will allow developers to expand the use of MWFeedParser to handle custom elements in their feeds or elements that are specific to the different formats.